In a codec such as H.264 advanced video coding (AVC) and high efficiency video coding (HEVC), motion vectors of blocks that are previously encoded and adjacent to a current block or co-located blocks in a previously encoded picture may be used for motion vector predictor of the current block in order to predict a motion vector of the current block.
In video encoding and decoding methods, in order to encode an image, one picture may be split into macro blocks and each of the macro blocks may be prediction encoded by using inter prediction or intra prediction.
Inter prediction is a method of compressing an image by removing temporal redundancy among pictures, and motion estimation encoding is a representative example of the inter prediction. In the motion estimation encoding, each of blocks in a current picture is predicted by using at least one reference picture. A reference block that is the most similar to the current block is searched for within a predetermined search range by using a predetermined evaluation function.
The current block is predicted based on the reference block, and a residual block that is obtained by subtracting a prediction block generated through the prediction from the current block is encoded. Here, in order to precisely perform the prediction, interpolation is performed on the search range of the reference picture to generate sub-pel-unit pixels smaller than integer-pel-unit pixels, and inter prediction is performed on the generated sub-pel-unit pixels.